/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package tv.pool.modelo;

import java.io.Serializable;
import javax.persistence.Embeddable;

/**
 *
 * @author ctrosch
 */
@Embeddable
public class BasesCondicionesPK implements Serializable {
    
    private String codigo;  
    private double nroitm;

    public BasesCondicionesPK() {
    }

    public BasesCondicionesPK(String codigo, double nroitm) {
        this.codigo = codigo;
        this.nroitm = nroitm;
    }

    public String getCodigo() {
        return codigo;
    }

    public void setCodigo(String codigo) {
        this.codigo = codigo;
    }

    public double getNroitm() {
        return nroitm;
    }

    public void setNroitm(double nroitm) {
        this.nroitm = nroitm;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final BasesCondicionesPK other = (BasesCondicionesPK) obj;
        if ((this.codigo == null) ? (other.codigo != null) : !this.codigo.equals(other.codigo)) {
            return false;
        }
        if (Double.doubleToLongBits(this.nroitm) != Double.doubleToLongBits(other.nroitm)) {
            return false;
        }
        return true;
    }

    @Override
    public int hashCode() {
        int hash = 3;
        hash = 97 * hash + (this.codigo != null ? this.codigo.hashCode() : 0);
        hash = 97 * hash + (int) (Double.doubleToLongBits(this.nroitm) ^ (Double.doubleToLongBits(this.nroitm) >>> 32));
        return hash;
    }

    @Override
    public String toString() {
        return "BasesCondiconesPK{" + "codigo=" + codigo + "nroitm=" + nroitm + '}';
    }

    


}
